package com.googlecode.recycled.data;

/**
 * Implementors of this interface are capable of returning persistent entity id.
 *
 * @param <I> Type of id.
 */
public interface WithId<I> {

    /**
     * Returns persistent entity id.
     *
     * @return Id if entity is persisted. Null if entity is transient.
     */
    I getId();

}
